import { get } from "../utils/request";

//获取推荐歌单
export const reqmusic = (limit = 99) => get(`/personalized?limit=${limit}`);

//获取歌单所有歌曲
export const reqmusics = (id) => get("/playlist/detail", { id: id });

//获取详细歌曲信息
export const reqdetailAPI = (ids) => get(`/song/detail?ids=${ids}`);

//获取音乐url
export const getUrlAPI = (id) => get(`/song/url?id=${id}`);

//获取歌词
export const getTextAPI = (id) => get(`/lyric?id=${id}`);

//获取歌曲详情
export const getSongsDetail = (id) => get(`/song/detail?ids=${id}`);

//登录接口
export const Login = (phone, password) =>
  get(`/login/cellphone?phone=${phone}&password=${password}`);

//获取轮播图
export const getBanner = () => get(`/banner?type=1`);

//获取歌手分类列表
export const getsinger = (num) =>
  get(`/artist/list?type=2&area=7&limit=${num}`);
//获取歌手热门歌曲 默认50条
export const getsingsongs = (id) => get(`/artist/top/songs?id=${id}`);
//获取歌手描述
export const getplayerAPI = (id)=>get(`/artist/desc?id=${id}`)
//获取最新 mv
export const getMvs = (num) => get(`/mv/first?limit=${num}`);
//获取mv播放地址
export const getmvurl = (id) => get(`/mv/url?id=${id}`);
//获取mv详情和清晰度
export const getword = (mid) => get(`/mv/detail/info?mvid=${mid}`);

//搜索单曲mv等等
export const searchAPI =(key)=>get(`/search/suggest?keywords=${key}`);

//获取歌手单曲
export const getuseroneAPI =(id)=>get(`/artists?id=${id}`)

//获取歌手MV
export const getUserMv = (id)=>get(`/artist/mv?id=${id}`)

//获取歌手专辑

export const getplaymainAPI=(id)=>get(`/artist/album?id=${id}&limit=30`)

//获取专辑评论

export const getplaywirteAPI=(id)=>get(`/comment/album?id=${id}`)

//获取mv评论
export const getmvAPI=(id)=>get(`/comment/mv?id=${id}`)